package com.runfast.waimai.service;

import com.runfast.common.service.IService;
import com.runfast.waimai.dao.model.RunfastBusiness;
import com.runfast.waimai.dao.model.RunfastBusinessExample;
import org.apache.ibatis.annotations.Param;
import org.springframework.data.domain.Pageable;

import java.util.List;
import java.util.Map;

public interface RunfastBusinessService extends IService<RunfastBusiness, Integer, RunfastBusinessExample> {
    List<RunfastBusiness> selectBusinessByExampleWithPageable(Map<Object,Object> map);
    List<RunfastBusiness> selectBusinessWithGoods(Map<Object,Object> map1);
    Integer countByMap(Map<Object,Object> map);
    Integer countBusinessByExample(Map<Object,Object> map);

    List<RunfastBusiness> selectAcivityByExampleWithPageable(Map<Object,Object> map);
    Integer countAcivityByExampleWithPageable(Map<Object,Object> map);
    Integer countAcivityByExample(Map<Object,Object> map);
    List<RunfastBusiness>  selectRankByMapWithPageable(Map<Object,Object> map);
    Integer countRankByMapWithPageable(Map<Object,Object> map);

    /** 商家参入的活动信息*/
    void setActivityToBusiness(RunfastBusiness business);

    List<RunfastBusiness> getAcivityBusinessByExampleWithPageable(Integer agentId, Integer activityId, Integer selectType, Integer businessId, String businessName,Pageable pageable);
    Integer countAcivityBusinessByExampleWithPageable(Integer agentId, Integer activityId, Integer selectType, Integer businessId, String businessName,Pageable pageable);
    Map<String,String> getOnlineActivity(Integer agentId, String ptype, Integer activityId, Integer businessId);
}